﻿<%@ Page Language="C#" MasterPageFile="~/Views\Home\test.master" Inherits="System.Web.Mvc.ViewPage" %>
 		<asp:Content ContentPlaceHolderID="test" runat="server">
 			<div class="tab_container">
   				
   				 <div id="tab5" class="tab_content">
   				 	<div class="sub_content">MY ACCOUNT</div>
   				  	<div class="success" id="accountsuccess">Account successfully edited.</div>
   				 	<div class="error" id="accounterror">Unable to edit. Username already exists. Try another username.</div>
   				 	<div class="error" id="accountemail">Unable to edit. Incorrect format of email address.</div>
   				 	<div class="error" id="accounterror2">Unable to edit. Please fill all the necessary information.</div>
   				 	<table width="100%" cellspacing="0" id="ab_table">
   				 	<tr><td>Username: </td><td><input type="text" size="35" id="editusername" disabled="disabled" value="<%= Html.Encode(Session["username"]) %>" /></td></tr>
   				 	<tr><td>First Name: </td><td><input type="text" size="35" id="editfirstname" disabled="disabled" value="<%= Html.Encode(Session["fname"]) %>" /></td></tr>
   				 	<tr><td>Last Name: </td><td><input type="text" size="35" id="editlastname" disabled="disabled" value="<%= Html.Encode(Session["lname"]) %>" /></td></tr>
   				 	<tr><td>E-mail: </td><td><input type="text" size="35" id="editemail" disabled="disabled" value="<%= Html.Encode(Session["email"]) %>" /></td></tr>
   				 	<tr><td>Contact Number: </td><td><input type="text" size="35" id="editcontact" disabled="disabled" value="<%= Html.Encode(Session["contactnumber"]) %>" /></td></tr>
   				 	</table>
   				 	<br/>
   				 	<div class="error" id="pass_error">Password entered is incorrect.</div>	
   				 	<div class="error" id="passconfirm_error">Passwords do not match. Try again.</div>			
   				 	<div class="success" id="pass_success">Password successfully changed.</div>	
   				 	<div id="changePassword">
   				 	<table width="100%" cellspacing="0" id="ab_table" display="none">
   				 	<tr><td>Old password:</td><td align="left"><input size="35" type="password" id="oldPassword" /></td></tr>
   				 	<tr><td>New password:</td><td align="left"><input size="35" type="password" id="newPassword" /></td></tr>
   				 	<tr><td>Verify password:</td><td align="left"><input size="35" type="password" id="confirmNewPassword" /></td></tr>
   				 	</table>
   				 	<br/>
   				 	<input type="button" id="editPassword" value="Confirm" />&nbsp;&nbsp;&nbsp;<input type="button" id="cancelEditPassword" value="Back" />
   				 	</div>
   				 	<div id="editAccounts"><input type="button" id="editAccountFinal" value="Save Changes" />&nbsp;&nbsp;&nbsp;<input type="button" id="cancelEditAccount" value="Cancel" /></div>
   				 	<div id="normalAccount"><input type="button" id="editAccount" value="Edit Account" />&nbsp;&nbsp;&nbsp;<input type="button" id="changePass" value="Change Password" /></div>
   				 </div>
   				 
   			</div>
 			
 		</asp:Content>
 		<asp:Content ContentPlaceHolderID="menu" runat="server">
	 		<div id="menu_container">
	 		
	 			<p>Welcome  <%= Html.Encode(Session["fname"])+ ' ' + Html.Encode(Session["lname"]) %>!</p>
	 			<div style="border-bottom: #E2E1E1 1px solid; padding-top: 30px;">
	 				<br/>
	 			</div>
	 			<ul class="tabs">
	               <% if(Html.Encode(Session["level"]) == "3"){ %>
	                	<li><a class="links" href="/Librarian">Search Books</a></li>
	                	<li><a class="links" href="/Librarian/UserAccount">View User's Account</a></li>
	                	<li><a class="links" href="/Book/Manage">Manage Books</a></li>
	                	<li><a class="links" href="/Librarian/ManageUser">Manage User</a></li>
	                <%} %>
	                <% else if(Html.Encode(Session["level"]) =="1") { %>
	                	<li><a class="links" href="/User/Index">Search Books</a></li>
	                <% } %>
	                <li class="active"><a class="links">My Account</a></li>
	            </ul>
	            <div style="border-top: #FFF 1px solid;">&nbsp;</div>
	        </div>
 		</asp:Content>
 	
 	
